'''
Created on 30.11.2009

@author: stud
'''

        
from Tkinter import *
from ScrolledText import *
root = Tk()
root.title('Texttest')
textfenster = ScrolledText(root,width =90)
textfenster.pack()
eingabe = Entry(root,width=70)


eingabe.pack(side=LEFT)

def hole():
    textfenster.insert(END, '\n' + eingabe.get())
def loesche():
    textfenster.delete('1.0',END)
def ende():
    root.destroy()
def callback(event):
    textfenster.insert(END, '\n' + eingabe.get())

        
but = Button(root,text='Hole', command = hole)
but.pack(side = LEFT)
but2 = Button(root,text='Staubsauger', command = loesche)
but2.pack(side = LEFT)
but3 = Button(root,text='EXIT', command= ende)
but3.pack(side = LEFT)


eingabe.bind('<Return>', callback)
root.mainloop()
